package infore.com.cn.util;

import java.sql.Connection;
import java.sql.SQLException;

public class DBUtil {
	public static Connection openConn() {
		try {
		    return PooledDBA.getInstance().getConnection(); 
		} catch (Exception e) {
			return null;
		}
	}
	public static void closeConn(Connection con) {
		try {
			if(con!=null){
				con.close();
			}	
		} catch (SQLException e) {
			e.printStackTrace();
		}
	}
	
	public static void main(String[] args) {
		System.out.println(DBUtil.openConn());
	}

}
